feat: don't automatically install frontend dependencies as part of assets:precompile#565
Draft
feat: don't automatically install frontend dependencies as part of assets:precompile#565
assets:precompile#565Conversation
…ssets:precompile`
JacobBriggsAckama
approved these changes
Oct 8, 2024
joshmcarthur
approved these changes
Oct 8, 2024
Contributor
Author
|
It seems like our capistrano based deployments are relying on this, which makes sense (especially since we're not sharing I still think the underlying change is good because for other situations like Docker and Heroku, this results in more work being done |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This (for me at least) was always a bit of a weird one and something we introduced to be on the safe side rather than as a behaviour we'd explicitly decided was a good thing.
From what I understand it was born from webpacker/shakapacker having this behaviour as the default, which then later changed around shakapacker v6/v7 before finally being definitely removed in v8.
Now that it is gone, I think we should axe our task too as we generally always have our dependencies installed by this point and combining these two independent actions is horrible for caching (i.e. in images you typically copy just the
package.json+ lockfile, do the install command, then copy everything else and proceed), can undo optimizations (i.e. if in the aforementioned docker image I decide to install just my production dependencies, this'll then undo that), and even hide subtle "bugs" (i.e. if we forget to actually install our dependencies, this'll hide that which while technically does avoid an error, means we might not realize there's a larger issue with our pipeline).